<template>
  <audio class="onekit-audio"
         :class="onekitClass"
         :style="onekitStyle"
         :id="onekitId"
         :src="src"
         :loop="loop"
         :controls="controls"
         :poster="poster">
    <slot></slot>
  </audio>
</template>

<script>
import weixin_behavior from "../../behaviors/weixin_behavior"
import onekit_behavior from "../../behaviors/onekit_behavior"
export default {
  name: "onekit-audio",
  mixins: [weixin_behavior, onekit_behavior],
  props: {
    "src": {
      type: String,
      default: ''
    },
    "loop": {
      type: [Boolean, String],
      default: false
    },
    "controls": {
      type: [Boolean, String],
      default: false
    },
    "poster": {
      type: String,
      default: ''
    },

  },
  methods: {
    // view_click:function(e){
    // 	this.$emit('click',e.details)
    // },
    // view_click:function(e){
    // 	//console.log("image load success",e)
    // 	this.$emit('tap',e.details)
    // },
  },
  mounted () {
    console.log(this.src)
  }
}
</script>

<style>
</style>
